<!-- inc:global_head -->
<!-- inc:right.css -->
<!-- inc:right.head -->

<!-- 玩家管理 -->
<!-- if($sysAct == "add" || $sysAct == "modify") -->
<div class="table2" style="text-align:left;">
	<a href="admin.php?file=index">系统首页</a> &raquo;
	<a href="admin.php?file=user&act=list">玩家列表</a> &raquo;
	<!-- if($sysAct == "add") -->添加新玩家<!-- else -->编辑玩家<!-- end -->
	<input type="button" value="玩家列表" onclick="qgurl('admin.php?file=user&act=list')">
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<form method="post" action="admin.php?file=user&act=viewok&id={:$id}" onsubmit="return add_msg();">
<tr>
	<td class="left">账号：<span style="color:red;">*</span></td>
	<td class="right">
		<input type="text" name="username" id="username" value="{:$rs[username]}">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">密码：<span style="color:red;">*</span></td>
	<td class="right">
		<input type="text" name="password" id="password" value="{:$rs[password]}">
		<!-- if($sysAct == "modify") -->
		<span class="clue_on">[不修改密码请不要改动内容]</span>
		<!-- else -->
		<span class="clue_on">[默认密码是123456]</span>
		<!-- end -->
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">邮箱：</td>
	<td class="right">
		<input type="text" name="email" id="email" value="{:$rs[email]}">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">现有元宝：</td>
	<td class="right">
		<input type="text" name="current_money" id="current_money" value="{:$rs[current_money]}">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">总计元宝：</td>
	<td class="right">
		<input type="text" name="total_money" id="total_money" value="{:$rs[total_money]}">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">证件号码：</td>
	<td class="right">
		<input type="text" name="status" id="status" value="{:$rs[status]}" class="long_input">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">安全问题：</td>
	<td class="right">
		<input type="text" name="question" id="question" value="{:$rs[question]}" class="short_input">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">安全答案：</td>
	<td class="right">
		<input type="text" name="answer" id="answer" value="{:$rs[answer]}" class="short_input">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">注册时间：</td>
	<td class="right">
		<input type="text" name="reg_time" id="reg_time" value="{run:echo date('Y-m-j',$rs[reg_time]);}" class="short_input">
	</td>
</tr>
</table>
</div>

<div class="table" onmouseover="this.className='table table1'" onmouseout="this.className='table'">
<table width="100%">
<tr>
	<td class="left">注册IP：</td>
	<td class="right">
		<input type="text" name="reg_ip" id="reg_ip" value="{:$rs[reg_ip]}" class="short_input">
	</td>
</tr>
</table>
</div>


<!-- run:$button_msg = $sysAct == "modify" ? "编辑玩家" : "添加玩家";-->
<div class="table">
<table width="100%">
<tr>
	<td class="left"></td>
	<td class="right"><input type="submit" id="creat_button" class="mybutton_01" value="{:$button_msg}"> &nbsp; <span id="show_step" style="color:red;"></span></td>
</tr>
</form>
</table>
</div>
<script type="text/javascript">
function add_msg(msg)
{
	var username = $("username").value;
	if(!username)
	{
		alert("账号不允许为空");
		return false;
	}

	$("show_step").innerHTML = "<img src='images/loading.gif' border='0' align='absmiddle'> 正在保存数据，如果网页没有动静请刷新...";

	$("creat_button").disabled = true;
}
</script>

<!-- elseif($sysAct == "list") -->
<div class="table2" style="text-align:left;">
	<a href="admin.php?file=index">系统首页</a> &raquo;
	玩家列表
	<input type="button" value="添加新玩家" onclick="qgurl('admin.php?file=user&act=add')">
</div>

<div class="table">
	<table cellpadding="1" cellspacing="0">
	<form method="post" action="admin.php?file=user&act=list">
	<tr>
		<td><input type="text" name="keywords" id="keywords" value="{:$keywords}"></td>
		<td>
			<select name="stype" id="stype">
			<option value="user"{if($stype == "user")} selected{end}>玩家</option>
			<option value="email"{if($stype == "email")} selected{end}>邮箱</option>
			<option value="u_id"{if($stype == "u_id")} selected{end}>ID</option>
			</select>
		</td>
		<td>
			<input type="submit" value="搜索" class="mybutton_01">
		</td>
			<td>
			<a href="admin.php?file=user&act=list">用户 I D排序</a>
		</td>
			<td>
			<a href="admin.php?file=user&act=listm">现有元宝排序</a>
		</td>
					<td>
			<a href="admin.php?file=user&act=listt">共有元宝排序</a>
		</td>
		</form>
	</tr>
	</table>
</div>

<table width="100%" cellpadding="0" cellspacing="0">
<tr>
	<td style="border-bottom:1px #D4D4D4 solid;"><img src="images/blank.gif" border="0" width="1" height="1"></td>
</tr>
</table>

<table width="100%" cellpadding="0" cellspacing="0">
<tr class="table table2">
	<td height="23px" class="msg_subject_id b_b">玩家ID</td>
	<td class="msg_subject b_b">玩家账号</td>
	<td class="msg_subject b_b">玩家邮箱</td>
	<td class="msg_subject b_b"><a href="admin.php?file=user&act=listm">现有元宝</a></td>
	<td class="msg_subject b_b"><a href="admin.php?file=user&act=listt">曾有元宝</a></td>
	<td class="msg_subject b_b">注册 I P</td>
	<td class="msg_postdate b_b">操作</td>
</tr>
<!-- $rslist AS $key=>$value -->
<tr class="m_out" onmouseover="this.className='m_over'" onmouseout="this.className='m_out'">
	<td height="25px" align="center" class="b_b">{:$value[u_id]}</td>
	<td align="left" class="b_b">{:$value[username]}</td>
	<td align="left" class="b_b">{:$value[email]}</td>
	<td align="left" class="b_b">{:$value[current_money]}</td>
	<td align="left" class="b_b">{:$value[total_money]}</td>
	<td align="left" class="b_b">{:$value[reg_ip]}</td>
	<td align="center" class="b_b">
		<input type="button" value="编辑" class="mybutton_01" onclick="qg_modify({:$value[u_id]})">
		<input type="button" value="删除" class="mybutton_01" onclick="qg_delete({:$value[u_id]})">
	</td>
</tr>
<!-- end -->
</table>

<div align="right">{:$pagelist}</div>
<script type="text/javascript">
function qg_modify(id)
{
	window.location.href="admin.php?file=user&act=modify&id="+id;
}
function qg_delete(id)
{
	//判断是否删除
	question = confirm("确认删除该信息吗？特别说明，删除后无法恢复！");
	if (question != "0")
	{
		qgurl("admin.php?file=user&act=delete&id="+id);
	}
}
</script>
<!-- end -->